#ifndef lcthw_Queue_h
#define lcthw_Queue_h

#include <stdlib.h>

// 链表栈的结点
typedef struct QueueNode {
    struct QueueNode *next;
    void *value; //无类型指针，可指向任何
} QueueNode;
//栈
typedef struct Queue {
    int count;
    QueueNode *first;
    QueueNode *last;
} Queue;

// #define Queue_create() Queue *Queue=(Queue *)malloc(sizeof(Queue)); Queue->count = 0;Queue->top = NULL; return Queue;


#define Queue_count(A) (A->count)
#define Queue_peek(A) ((A)->first->value)

#define Queue_destroy(A) while(Queue_count(A)) { Queue_recv(A); } free(A);



#define QUEUE_FOREACH(L, V)     QueueNode *V = NULL;\
    for(V = L->first; V != NULL; V  = V->next)



#endif
